In general, a processor installed in a mobile apparatus consumes a large portion of energy consumed in the mobile apparatus as mobile computing operations become complicated and a demand for an embedded system increases.
Electric power consumption of the processor is proportional to not only an operation frequency of the processor but also the square of a voltage thereof. Thus, to reduce the voltage of the processor is the most efficient way in reducing the electric power consumption of the processor. However, in case the voltage of the processor is reduced, the operational frequency thereof need be also reduced depending on the reduced voltage, so that the performance of the system is deteriorated.
In order to keep the balance between the performance of the system and the electric power consumption thereof, dynamic voltage scaling (DVS) is a technique for scaling the dynamic voltage of the processor at run-time by a voltage scheduler to reduce the energy consumption.
FIGS. 1A and 1B show graphs which represent schematic examples of shutdown mechanism and DVS. The shutdown mechanism is a conventional technique for reducing the electric power consumption, which is a way for stopping the operation of the processor during idle time.
Referring to FIGS. 1A and 1B, a horizontal axis represents time T, while a vertical axis indicates voltage V and clock frequency. W1, W2 and W3 are areas of works, which mean workloads.
The workloads W1, W2 and W3 are performed with a maximum voltage, it is shutdown during the idle-time, and the total energy consumption is 8 energy unit as shown in FIG. 1A.
On the contrary, the voltages in FIG. 1B, are set respectively for 3/5 V, 1/3 V and 2/3 V, so that the total energy consumption is 2.97 energy unit ((3/5)2×(3/5)×5+(1/3)2×(1/3)×3+(2/3)2×(2/3)×6=2.97).
In order to minimize the energy consumption by adjusting the voltage, the workload should be predicted precisely to apply a clock speed and voltage suitable for the workload to the system. The prediction of the next workload is usually realized by analyzing the previous system workload. However, it is difficult to predict the workload precisely in case the workload is changed greatly.
A plurality of voltages and operation frequency levels for use in many processors can be changed dynamically by a user's demand. Moreover, a DC—DC converter is capable of efficiently making latency based on voltage change minimized.
Now, multimedia occupies a large part on applications for the mobile computing more and more, so that a MPEG decoder is one of these applications to require a large electric power in the processor.
One of the features of the MPEG decoder is that the time required in decoding a frame varies widely, from frame to frame, due in part to the fact that a given MPEG video stream contains different frame types, and in part to the potential wide variation between scenes, which makes it difficult to predict the next workload based on the previous workload, so that a voltage can be adjusted inefficiently.
A MPEG stream for use in MPEG decoding includes an array of frames. The frames have I, P and B frames and are repeated according to a regular rule. The set of the minimum unit frames repeated according to the regular rule is called Group Of Pictures GOP.
The decoding time of these frames is proportional to the size of a frame and is set diversely according to the type of the frame. There is a method for predicting the decoding time of an arbitrary system by using the type and size of the frame, which is described in “Predicting MPEG execution time, SIGPMETRICS/PERFORMANCE 98, Int., 1 Conf. on Measurement and Modeling of computer Systems: 131-140 (1998.6)”.
Another feature of the MPEG decoding is that it should support a real-time decoding. The technique applied in order to support the real-time decoding generates interrupts periodically during decoding to compare the number of set frames from the previous interrupt with the number of actually current frames to thereby adjust the decoding speed, wherein the number of the set frames is the number of the frames which should be passed while the number of the actually current frames is the number of the passed frames.
There are two modes for supporting the real-time decoding, wherein one is a delay mode, which delays time through busy waiting or sleep operation as much as the delayed time is set in proportional to the high speed of the system during decoding the frames in case the system speed is higher than that for the real-time decoding, while the other is a drop mode, which drops the frames selectively at a drop rate set in proportional to the low speed of the system in case the system speed is lower than that for the real-time decoding.
Referring to FIG. 2, there is shown that two frames are more decoded during one second in case the number of the frames per second is 30. The busy waiting or sleep operation is performed during decoding a next frame by a diff value. The diff value means an allocated variable, i.e., the number of exceeded frames. The diff value shows how close the actual system speed is to the system speed for the real-time decoding, so that more frames than frames fixed per second are played if the diff value is a positive integer, while less frames than the frames fixed per second are played if the diff value is a negative integer.
Referring to FIG. 3, a delay value is increased according to the number of exceeded frames in case the diff value is a positive integer and a previous mode is a delay mode, while a frame drop rate is decreased in proportional to the number of the exceeded frames or a drop mode is changed to the delay mode in case the diff value is a positive integer and the previous mode is the drop mode. It is the opposite in case the diff value is a negative integer.
As described above, the busy waiting or sleep operation has drawbacks in the electric power consumption in that it is generated in delaying the time for the real-time decoding. Also, the method for setting a delay value according the previous mode is based on how close the decoding is performed to the real-time decoding at previous time intervals, so that the value can be inaccurate since the workload is changed considerably in the MPEG decoding. Moreover, the diff value becomes large in case the workload is changed considerably, so that it leads to deteriorate the real-time decoding by dropping many frames or allocating delay values unnecessarily.